#!/bin/sh

# 加载工具类
. /etc/idnewnil/utils.sh

# 配置WAN连接
if [ "$(getstr '.wan.protocal')" = pppoe ]; then
    uci set network.wan.proto='pppoe'
    uci set network.wan.username=$(getstr '.wan.username')
    uci set network.wan.password=$(getstr '.wan.password')
    uci set network.wan.ipv6='auto'
    uci commit network
fi